package com.mzj.saas.rent;

import com.haixiaoke.saas.repository.core.AjaxResult;
import com.haixiaoke.saas.repository.core.BaseController;
import com.haixiaoke.saas.repository.pojo.TimeRange;
import com.haixiaoke.saas.repository.service.ITimeRangeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 时间区间Controller
 *
 * @author zhiping
 * @date 2023-04-11
 */
@RestController
@RequestMapping("/base/timeRange")
public class TimeRangeController extends BaseController {

    @Autowired
    private ITimeRangeService timeRangeService;

    /**
     * 查询时间区间列表
     */
    @GetMapping("/list")
    public AjaxResult list(TimeRange timeRange) {
        return success(timeRangeService.selectTimeRangeList(timeRange));
    }

}
